<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<title></title>
</head>
<body>
<script type="text/javascript">
	/*筛选数组方法1*/
	const arr1=[2,0,6,1,77,0,52,0,25,7]
	const newArr1=[]
	arr1.forEach((item)=>{
		if (item>=10) {
			newArr1.push(item)
		}
	})
	console.log(newArr1)

	/*筛选数组方法2*/
	const arr2=[2,0,6,1,77,0,52,0,25,7]
	const newArr2=arr2.filter((item)=>{
		return item>=10
	})
    console.log(newArr2)
</script>
</body>
</html>